export type OrderPageResult = PageResult<OrderPageVO[]>;

/**
 * 订单查询参数
 */
export interface OrderQuery extends PageQuery {
  page?: number;
  limit?: number;
  keywords?: string;
}

/**
 * 分页对象
 */
export interface OrderPageVO {
  id?: number;
  name?: string;
  sort?: number;
  status?: number;
  total_price?: number;
  refund_price?: number;
  out_trade_no?: string;
  current_status: number;
  remark?: string;
  createTime?: Date;
  updateTime?: Date;
}

/**
 * 退款参数
 */
export interface OrderRefundVo {
  id?: number;
  type?: number; // 0：全额退款 1：部分退款
  price?: number; //退款金额
  reason?: string; //部分退款理由
  out_trade_no?: number;
}

/**
 * 订单对象
 */
export interface OrderForm {
  id?: number;
  sort?: number;
  status?: number;
  current_status?: number;
  products?: any;
  address?: any;
  out_trade_no?: number;
  buyer_remark?: string;
  deliver_time?: number;
  create_time?: string;
  pay_time?: string;
  cancel_time?: string;
  refund_time?: string;
}

/**
 * 退款对象
 */
export interface OrderRefundForm {
  id?: number;
  refund_price?: number; //退款金额
  refund_note?: string; //退款备注
}
